GestureDetector(
    behavior: HitTestBehavior.translucent,
    onTap: () {
        // 触摸收起键盘
        FocusScope.of(context).requestFocus(FocusNode());
    },
    child: *******
}

注:一定要放到最外层


落叶归根
3 声望1 粉丝